x32 defines __x86_64__ but uses the ILP32 ABI, so the LP64
sizeof(MYSQL) == 1272 compile-time assert is selected incorrectly
and breaks the build.
Guard the x86_64 check with !defined(__ILP32__) so the LP64 size assert
only applies to real amd64 LP64 builds, while leaving the existing
Windows amd64 and i386 checks unchanged.
(cherry-picked from
936f04c4f9bd5d66014942bd27e1996b2e740626)
Merged on 10.11, and will be included in next release (10.11.19+, 11.8.9+).
Forwarded: https://github.com/MariaDB/server/pull/4962
Gbp-Pq: Name MDEV-34195-tests-avoid-LP64-MYSQL-size-assert-on-x32.patch
*/
#if defined _M_AMD64
compile_time_assert(sizeof(MYSQL) == 1208);
-#elif defined __x86_64__
+#elif defined(__x86_64__) && !defined(__ILP32__)
compile_time_assert(sizeof(MYSQL) == 1272);
#elif defined __i386__
compile_time_assert(sizeof(MYSQL) == 964);